<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Insert title here</title>
<style type="text/css">
*{
	list-style: none;
	text-decoration: none;
}
#all{
	margin-top: 10px;
	text-align: center;
	display: inline-block;
	
	
}
#table{
	border-spacing: 0;
	width:60%;
	margin: auto;
}
#table tr:nth-child(2n+1){
	background-color:#f1f1f1;
	width: 300px;
}
#table tr:nth-child(2n){
	background-color:#ffffff;
	width: 300px;
}
#table td{
	width: 300px;
}
#all th{

}
#a{
	margin-left: 20%;
}


</style>
</head>
<body>
<form action="/employee/findall8">
	<p id="a">
	尾号为<input type="text" name="number">的学生信息
	<input type="submit" value="查询">
	
	</p>
</form>

<div id="all">
<form >
	<table border="1" id=table>
	<caption >所有员工基本信息表</caption>
		<tr>
			<th>员工编号</th>
			<th>姓名</th>
			<th>电话号码</th>
			<th>年龄</th>
			<th>薪水</th>
			<th>部门编号</th>
			<th>部门名称</th>
			<th>部门地址</th>
		</tr>
		<c:forEach items="${list }" var="e">
		<tr>
			<td>${e.id}</td>
			<td>${e.name}</td>
			<td>${e.phone}</td>
			<td>${e.age}</td>
			<td>${e.salary}</td>
			<td>${e.dept.id}</td>
			<td>${e.dept.deptName}</td>
			<td>${e.dept.deptAddr}</td>
			</td>
		</tr>
		</c:forEach>
	</table>
	
	<p><a href="/employee/insertemp">添加</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
	<a href="/employee/updateemp">修改</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
	<a href="/employee/deleteemp">删除</a>
	</p>
</form>


</body>
</html>